import time

from selenium import webdriver
from selenium.webdriver.common.by import By

# 1. 先创建浏览器驱动对象
driver=webdriver.Chrome()
# 2 通过get方法打开页面
driver.get("http://localhost:8081/regA.html")

# find_element(By.ID,"id的属性值")
# send_keys 往输入框里面输入数据
driver.find_element(By.ID,"userA").send_keys("admin")
#密码  值是123456

driver.find_element(By.ID,"passwordA").send_keys("123456")

time.sleep(5)

# 4. 关闭浏览器驱动对象
driver.quit()



